<%@page contentType="text/html;charset=UTF-8"%>
<%@ include file="/commons/taglibs.jsp"%>
<c:if test="${user!=null}">
	<c:set var="operat" value="update" scope="page"/>
</c:if>
<c:if test="${user==null}">
	<c:set var="operat" value="insert" scope="page"/>
</c:if>
<div class="pageContent">
	<form:form modelAttribute="user"  action="${ctx}/user/${operat}?navtabid=userNav" method="post"   onsubmit="return validateCallback(this, dialogAjaxDone);" >
	<div class="pageFormContent" layoutH="58">
			<input type="hidden" id="id" name="id" value="${user.id}"/>
			<p>
				<label>username:</label>
				<input name="username"  class="required" type="text"  value="${user.username}"/>
			</p>
			<p>
				<label>password:</label>
				<input name="password"  class="required" type="text"  value="${user.password}"/>
			</p>
		<p>
			<label>Status</label>
			<select name="accountNonLocked">
				<option value="1" ${'1' eq user.accountNonLocked ? 'selected="selected"' : ''}>ACTIVE</option>
				<option value="0" ${'0' eq user.accountNonLocked ? 'selected="selected"' : ''}>INACTIVE</option>
			</select>
		</p>
			<p>
				<label>email:</label>
				<input name="email"   type="text"  value="${user.email}"/>
			</p>
		</div>
		<div class="formBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button type="submit">保存</button></div></div></li>
				<li><div class="button"><div class="buttonContent"><button type="reset">清空</button></div></div></li>
				<li><div class="button"><div class="buttonContent"><button type="button" class="close">关闭</button></div></div></li>
			</ul>
		</div>
</form:form>
</div>
